package com.mxpio.erp.common.equipment.entity;


import com.mxpio.erp.common.jpa.model.OrderLine;
import com.mxpioframework.security.annotation.Dict;
import com.mxpioframework.security.entity.Dept;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

@Data
@EqualsAndHashCode(callSuper=false)
@Entity
@Table(name = "MB_ERP_EQUIPMENT_EQP_ALLOT_LINE")
@Schema(description = "设备台账调拨申请单明细行")
public class EquipmentEqpAllotApplyLine extends OrderLine {
	private static final long serialVersionUID = 1L;

/*	@Column(name = "EQP_ID_")
	@Schema(description = "设备(台账)ID")
	private String eqpId;

	@Column(name = "CODE_")
	@Schema(description = "设备资产编号")
	private String code;*/

	@Column(name = "BASICS_CODE_")
	@Schema(description = "设备资产ID")
	@Dict(dicCode = "basicsCode", dicEntity = EquipmentEqpBasics.class, dicText = "eqpName")
	private String basicsCode;

	@Schema(description = "调拨原因")
	@Column(name = "REASON_")
	private String reason;

	@Column(name = "ALLOT_USE_DEPT_ID_")
	@Schema(description = "调拨单位")
	@Dict(dicCode = "deptCode", dicEntity = Dept.class, dicText = "deptName")
	private String allotUseDeptId;

	@Column(name = "MEMO_")
	@Schema(description = "备注")
	private String memo;

	@Transient
	private EquipmentEqpBasics eqpBasics;
}
